home *** CD-ROM | disk | FTP | other *** search
/ Die Speccy' 97 / Die Speccy' 97.iso / amiga_system / the_aminet / disk / cdrom / a4k_atapi_ita.lha / a4000-atapi_ita / Installa < prev    next >
Text File  |  1995-09-26  |  16KB  |  583 lines

  1. ; ************************************************
  2. ; *
  3. ; * $VER: Install-ATAPI A4000 v1.00 Demo Vers (07.09.95)
  4. ; *
  5. ; * Installation for A4000 Atapi Package v 1.00
  6. ; *
  7. ; * Copyright ⌐ 1995 by Georg Campana
  8. ; *
  9. ; ************************************************
  10.  
  11. ;/// Variabili
  12. ; ****************************
  13. ;       Variabili
  14. ; ****************************
  15. ;
  16. (set DemoVersion        1) ; Demo Version
  17. (set ProductName        "A4000 ATAPI ITALIAN VERSION"  )  ; product name
  18. (set ProductBaseName    "A4000-Atapi")                    ; product base name
  19. (set VersionNum         "1.00 ")                     ; product version number
  20.  
  21. (set OSVersion          (/ (getversion) 65536))
  22. (set PctDone            0)
  23.  
  24. (set CPUOpts            0)    ; 0=68000,68010; 1=68020,68030,68040
  25.  
  26. (makeassign "CDPLUSPLUS" "" (safe))
  27.  
  28. (set Disk1Name                  "CDPLUSPLUS:")
  29.  
  30. (set MemSpace 1024)   ; 1K minimo di spazio necessario su disco
  31.  
  32. ;///
  33.  
  34. ;/// Proc setPkgOPts
  35. (procedure setPkgOpts
  36. ;
  37. ; ****************************
  38. ; * Wich Parts
  39. ; ****************************
  40. ;
  41.   (
  42.         (set PkgOpts
  43.                 (askoptions
  44.                         (prompt
  45.                            "Scegli le parti che vuoi installare"
  46.                            ("del pacchetto %s" ProductName)
  47.                         )
  48.                         (help
  49.                                 "Questa parte dell'installazione ti permette di scegliere quali moduli del"
  50.                                 (" pacchetto %s vuoi installare.\n" ProductName)
  51.                                 "\n"
  52.                                 "*** Atapi Device Driver\n"
  53.                                 "Questa opzione farα si che verrα installato il device"
  54.                                 " driver (cd.device )nella directory Devs: (Fondamentale)\n"
  55.                                 "\n"
  56.                                 "*** CDplusplusFS\n"
  57.                                 "Questa opzione installerα il file system proprietario"
  58.                                 " della CD++ nella directory L: (Consigliato).\n"
  59.                                 "\n"
  60.                                 "*** MAP-Mini Atapi Player\n"
  61.                                 "Questa opzione installerα una utility che permette la"
  62.                                 " riproduzione di CD-Audio anche misti.\n"
  63.                                 "\n"
  64.                                 "*** TRKDownLoad Track-Downloader\n"
  65.                                 "Questa opzione farα installare un utility che permette"
  66.                                 " il salvataggio su file di parti di tracce audio o dati.\n"
  67.                                 "\n"
  68.                                 "*** PlayCDXL\n"
  69.                                 "Questa opzione installerα un utility che permette la"
  70.                                 " riproduzione in tempo reale di film CDXL.\n"
  71.                                 "\n"
  72.                                 @askoptions-help
  73.                         )
  74.                         (choices
  75.                                 ; bit position 0 -- todo & 1
  76.                                 ;
  77.                                 "Atapi Device Driver          (16 Kbytes)"
  78.  
  79.                                 ; bit position 1 -- todo & 2
  80.                                 ;
  81.                                 "CDplusplusFS - CD Filesystem (23 Kbytes)"
  82.  
  83.                                 ; bit position 2 -- todo & 4
  84.                                 ;
  85.                                 "MAP- Mini Atapi Player       ( 9 Kbytes)"
  86.  
  87.                                 ; bit position 3 -- todo & 8
  88.                                 ;
  89.                                 "TRKDownLoad- Track DownLoader(15 Kbytes)"
  90.  
  91.                                 ; bit position 4 -- todo & 16
  92.                                 ;
  93.                                 "PlayCDXL - Player Film CDXL  (30 Kbytes)"
  94.  
  95.                         )
  96.                 )
  97.         )
  98.   )
  99. )
  100. ;///
  101.  
  102. ;/// Proc setDirPath
  103.  
  104. (procedure setDirPath
  105. ;
  106. ; ****************************
  107. ; * Ask the user for a directory name.
  108. ; ****************************
  109. ;
  110. ; these variables must be defined before calling this procedure:
  111. ;    setDirPathWhy
  112. ;    setDirPathHelp
  113. ;    DirPath
  114. ;
  115. ; this procedure returns the selected directory in DirPath
  116. ;
  117.    (
  118.  
  119.        (set DirPath
  120.                (askdir
  121.                        (prompt ("Seleziona il disco sul quale installare il pacchetto  ( Normalmente SYS: )" )
  122.  
  123.                        )
  124.                        (help   "Il Pacchetto verrα installato sul disco"
  125.                                " prescelto .\n"
  126.                                "Se volete installare il pacchetto su un dischetto"
  127.                                " bootabile inserite quest'ultimo e sceglietelo"
  128.                                " dalla lista che si presenta\n"
  129.                                "\n"
  130.                                @askdir-help
  131.                        )
  132.                        (disk)
  133.                        (default "SYS:")
  134.                )
  135.        )
  136.  
  137.  
  138.  
  139.    )
  140. )
  141. ;///
  142.  
  143. ;/// Proc AskFsIcon
  144. ;
  145. ;
  146. (procedure AskFsIcon
  147. ;
  148. ; This procedure ask of wich cd Icon you want to install with wich Name
  149. ; It requires initialization of variables:
  150. ;
  151. ; In "DefaultIcon" ci deve essere quella accesa di default
  152. ; Ridα in "IconChoose" qual icona
  153. ; 0 nessuna - 1 AmiCDFilesystem
  154. ; 2 AmiCDFS - 3 CDfilesystem - 4 CDplusplusFS
  155. ;
  156.   (
  157.     (set IconChoose
  158.      
  159.            (askchoice
  160.                 (prompt "Scegli per quale CD-Filesystem installare l'icona")
  161.                 (help
  162.                         "Potete scegliere per quale filesystem"
  163.                         " installare il pacchetto.\n"
  164.                         "Nel caso che abbiate installato il"
  165.                         " CDpluplusFS , scegliete quest'ultimo.\n"
  166.                         "\n"
  167.                         "Se il filesystem in vostro possesso"
  168.                         " non Φ presente tra quelli nella lista"
  169.                         " scegliete -Nessuno- e modificate nei"
  170.                         " tooltype dell'icona del vostro device"
  171.                         " CD la voce Device con\nDevice=cd.device\n"
  172.                         "e la voce Unit con\nUnit=0\n"
  173.                         @askchoice-help
  174.                 )
  175.                 (choices
  176.                         "-Nessuno"
  177.                         "-AmiCDFileSystem - by Nicola Salmoria"
  178.                         "-cdrom-handler   - by Frank Munkert"
  179.                         "-CDFileSystem    - by CBM Commodore"
  180.                         "-CDplusplusFS    - by CD++"
  181.                 )
  182.                 (default DefaultIcon)
  183.            )
  184.     )
  185.   )
  186. )
  187. ;///
  188.  
  189. ;/// Proc GetDevName
  190. ;
  191. ;  in DevName si ritrova il nome da usare per l'icona
  192. ;
  193.  
  194.  
  195. (procedure GetDevName
  196.    
  197.    (
  198.      (set DevName
  199.            (askstring
  200.                      (prompt "Scrivi il nome per il device CD-Rom senza i due punti\nEs. CD0")
  201.                      (help
  202.                              "Il nome scelto sarα quello del"
  203.                              " Device fisico\n"
  204.                              "E' conveniente non scegliere"
  205.                              " nomi troppo lunghi\n"
  206.                              "\nE' consigliabile CD0 o CD1 ecc."
  207.                              " dato che molti programmi cercano"
  208.                              " questo nome\n"
  209.                      )
  210.                      (default "CD0")
  211.            )
  212.      )
  213.    )
  214. )
  215. ;///
  216.  
  217. ;/// Proc AskAutoMount
  218. ;
  219. ;
  220. (procedure AskAutoMount
  221. ;
  222. ; Chiede se l'icona deve essere inserita nel devs Dosdrivers o nel
  223. ; storage dosdrivers
  224. ;
  225.   (
  226.     (set AutoMount
  227.      
  228.            (askbool
  229.                 (prompt "Vuoi che il device Atapi venga montato"
  230.                         " automaticamente ad ogni riavvio ,od"
  231.                         " a ogni accensione ?"
  232.                 )
  233.                 (help
  234.                         "Rispondendo positivamente l'icona del"
  235.                         " device verrα posta nel cassetto:\n"
  236.                         "Devs:Dosdrivers\n"
  237.                         "In questo modo il lettore CD-ROM sarα disponibile"
  238.                         " ad ogni riavvio o accensione della macchina\n\n"
  239.                         "Altrimemti in: Storage:DosDrivers\n"
  240.                         "ed il lettore sarα utilizzabile solo dopo aver cliccato due volte sulla sua Icona"
  241.                 )
  242.                 (choices
  243.                         "Monta al Riavvio"
  244.                         "No,Montaggio manuale"
  245.                 )
  246.                 (default 1)
  247.            )
  248.     )
  249.   )
  250. )
  251. ;///
  252.  
  253.  
  254. ; *************************************************************************
  255. ; *                         ACTUAL START OF SCRIPT
  256. ; *
  257. ; * Ask all questions for the user now, do all of the work later.
  258. ; *************************************************************************
  259. ;
  260. ;/// MAIN SCRIPT
  261. (onerror
  262.  
  263. )
  264. ; ****************************
  265. ;  Check for OS Version
  266. ; ****************************
  267.  
  268. (if (= DemoVersion 1)
  269.     (message "\n" "\n"
  270.              "Attenzione: Questa Φ una versione DEMO\n"
  271.              "del Pacchetto A4000 Atapi_Ita !\n"
  272.              "PUOI RIDISTRIBUIRE IL DISCO\n"
  273.              "COMPLETO A CHIUNQUE (tranne ai Crakker)" "\n"
  274.              "\n" "\n" "\n"
  275.              "Atapi Plug'n Play is Copyright by \n"
  276.              "Georg Campana & Marco Campinoti ⌐1994"
  277.              (help "Per avere la versione registrata , completamente funzionante leggete il manuale o chiamate : 0565/850621 e 0565/853005")
  278.     )
  279. )
  280.  
  281.  
  282. ; ****************************
  283. ; ****************************
  284. ;
  285.  
  286. (set DirPath "SYS:")
  287.  
  288. (setDirPath)
  289.  
  290. (set @default-dest DirPath)
  291.  
  292. (set devdest  (tackon @default-dest "Devs"))
  293. (set fsdest   (tackon @default-dest "L"))
  294. (set utildest (tackon @default-dest "Utilities"))
  295.  
  296.  
  297. (setPkgOpts)
  298.  
  299. (set DefaultIcon 0)
  300.  
  301. (if (= (exists (tackon fsdest "AmiCDFileSystem")) 1)
  302.     (set DefaultIcon 1)
  303. )
  304.  
  305. (if (= (exists (tackon fsdest "cdrom-handler")) 1)
  306.     (set DefaultIcon 2)
  307. )
  308.  
  309. (if (= (exists (tackon fsdest "CDFileSystem")) 1)
  310.     (set DefaultIcon 3)
  311. )
  312.  
  313. (if (IN PkgOpts 1)
  314.     (set DefaultIcon 4)
  315. )
  316.  
  317. (AskFsIcon)
  318.  
  319. (select IconChoose
  320.    (set FsName 0)
  321.    (set FsName "AmiCDFS")
  322.    (set FsName "AmiCDHandler")
  323.    (set FsName "CbmCDFS")
  324.    (set FsName "CDplusplusFS")
  325. )
  326.  
  327.  
  328. (set AutoMount 1)
  329. (set DevName "CD0")
  330.  
  331. (if (> @user-level 1)
  332.  
  333.     (if (<> IconChoose 0)
  334.         (
  335.          (GetDevName)
  336.          (AskAutoMount)
  337.         )
  338.     )
  339. )
  340.  
  341. (if (= AutoMount 1)
  342.     (set Icondest  (tackon @default-dest "Devs"))
  343.     (set Icondest  (tackon @default-dest "Storage"))
  344. )
  345.  
  346.  
  347.  
  348.  
  349.  
  350. (if (IN PkgOpts 0)
  351.     (set MemSpace (+ MemSpace 16000))
  352. )
  353. (if (IN PkgOpts 1)
  354.     (set MemSpace (+ MemSpace 23000))
  355. )
  356. (if (IN PkgOpts 2)
  357.     (set MemSpace (+ MemSpace  9000))
  358. )
  359. (if (IN PkgOpts 3)
  360.     (set MemSpace (+ MemSpace 30000))
  361. )
  362. (if (IN PkgOpts 4)
  363.     (set MemSpace (+ MemSpace 14000))
  364. )
  365. (if (<> IconChoose )
  366.     (set MemSpace (+ MemSpace 1000))
  367. )
  368.  
  369. (if (< (getdiskspace DirPath) MemSpace)
  370.     (if(> (getdiskspace DirPath) 0)
  371.        (
  372.           (abort "ATTENZIONE: Lo spazio disponibile\n"
  373.                  ("sul disco %s\n" DirPath)
  374.                  ("Φ di soli %ld bytes\n" (getdiskspace DirPath) )
  375.                  ("e ne servono almeno %ld\n" MemSpace)
  376.                  "\n"
  377.                  "Rilanciate l'icona di Installazione\n"
  378.                  "e selezionate meno utility , oppure\n"
  379.                  "cancellate qualche file dal vostro\n"
  380.                  ("disco %s\n" DirPath)
  381.           )
  382.        )
  383.     )
  384. )
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.  
  396.  
  397.  
  398.  
  399. ; if bit position 0 is on  Installa device
  400. (if (IN PkgOpts 0)
  401.      (
  402.  
  403.         
  404.         (if (< (exists devdest (noreq)) 2)
  405.  
  406.             (makedir devdest
  407.                (prompt "Creo una directory -Devs-")
  408.                (infos)
  409.             )
  410.         )
  411.  
  412.  
  413.         (copylib
  414.             (prompt "Installo Device Driver")
  415.             (source (tackon Disk1Name "devs/cd.device"))
  416.             (dest devdest)
  417.             (optional force)
  418.         )
  419.         
  420.  
  421.      )
  422. )
  423. ; if bit position 1 is on Installa FileSystem
  424. (if (IN PkgOpts 1)
  425.      (
  426.  
  427.         
  428.         (if (< (exists fsdest (noreq)) 2)
  429.  
  430.             (makedir fsdest
  431.                (prompt "Creo una directory -L-")
  432.             )
  433.         )
  434.  
  435.  
  436.         (copylib
  437.             (prompt "Installo FileSystem della CD++")
  438.             (source (tackon Disk1Name "l/CDplusplusFS"))
  439.             (dest fsdest)
  440.             (optional force)
  441.         )
  442.         
  443.  
  444.      )
  445. )
  446.  
  447. ; if bit position 2 is on Installa MAP
  448. (if (IN PkgOpts 2)
  449.      (
  450.  
  451.         
  452.         (if (< (exists utildest (noreq)) 2)
  453.  
  454.             (makedir utildest
  455.                (prompt "Creo una directory -Utilities-")
  456.                (infos)
  457.             )
  458.         )
  459.  
  460.  
  461.         (copyfiles
  462.             (prompt "Installo Mini Atapi Player")
  463.             (source (tackon Disk1Name "utilities/MAP"))
  464.             (dest utildest)
  465.             (infos)
  466.             (optional force)
  467.         )
  468.         
  469.  
  470.      )
  471. )
  472.  
  473. ; if bit position 3 is on Installa TRKDownLoad
  474. (if (IN PkgOpts 3)
  475.      (
  476.  
  477.         
  478.         (if (< (exists utildest (noreq)) 2)
  479.  
  480.             (makedir utildest
  481.                (prompt "Creo una directory -Utilities-")
  482.                (infos)
  483.             )
  484.         )
  485.  
  486.  
  487.         (copyfiles
  488.             (prompt "Installo TrkDownLoader")
  489.             (source (tackon Disk1Name "utilities/TRKDownLoad"))
  490.             (dest utildest)
  491.             (infos)
  492.             (optional force)
  493.         )
  494.         
  495.  
  496.      )
  497. )
  498.  
  499. ; if bit position 4 is on Installa PlayCDXL
  500. (if (<> DemoVersion 1)
  501.    (if (IN PkgOpts 4)
  502.         (
  503.  
  504.            
  505.            (if (< (exists utildest (noreq)) 2)
  506.  
  507.                (makedir utildest
  508.                   (prompt "Creo una directory -Utilities-")
  509.                   (infos)
  510.                )
  511.            )
  512.  
  513.  
  514.            (copyfiles
  515.                (prompt "Installo PlayCDXL")
  516.                (source (tackon Disk1Name "utilities/PlayCDXL"))
  517.                (dest utildest)
  518.                (infos)
  519.                (optional force)
  520.            )
  521.            
  522.  
  523.         )
  524.    )
  525. )
  526. (if (> IconChoose 0)
  527.     (
  528.         (if (< (exists Icondest (noreq)) 2)
  529.  
  530.             (makedir Icondest
  531.                (prompt "Creo una directory Devs o Storage")
  532.                (infos)
  533.             )
  534.         )
  535.  
  536.         (set Icondest  (tackon Icondest "Dosdrivers"))
  537.          
  538.         (copyfiles
  539.             (prompt "Installo l'Icona del Device")
  540.             (source (tackon Disk1Name (tackon "Devs/Storage" FsName)))
  541.             (dest IconDest)
  542.             (newname  DevName)
  543.             (infos)
  544.             (optional force)
  545.         )
  546.  
  547.     
  548.         (if (= AutoMount 1)
  549.             ( message "\n" "\n"
  550.                    "Ad ogni riavvio del calcolatore o ad ogni\n"
  551.                    "accensione- il lettore CD-ROM verrα \"Montato\"\n"
  552.                    "automaticamente !\n"
  553.                    "\n"
  554.                    "Potete disabilitare questo automatismo\n"
  555.                    ("trascinando l'icona %s dal cassetto " DevName)
  556.                    "Devs/Dosdrivers nel cassetto Storage/Dosdrivers\n"
  557.             )
  558.             ( message "\n" "\n"
  559.                    "Potete \"Montare\"\n il lettore CD-ROM\n"
  560.                    ("cliccando semplicemente sull'Icona %s\n" DevName)
  561.                    "nel cassetto Storage/Dosdrivers\n"
  562.                    "Per abilitare il montaggio automatico\n"
  563.                    "trascinate l'Icona nel cassetto Devs/Dosdrivers"
  564.             )
  565.         )
  566.     )
  567.     ( message "\n" "\n"
  568.            "Non Φ stata installata alcuna Icona per\n"
  569.            "il montaggio del lettore CD-ROM .\n"
  570.            "E' necessario quindi costruirsi quest'ultima\n"
  571.            "autonomamente seguendo le istruzioni del\n"
  572.            "proprio filesystem !\n"
  573.            "\n"
  574.            "Potete anche rilanciare l'icona di installazione\n"
  575.            "e selezionare un filesystem alla richiesta\n"
  576.     )
  577.  
  578. )
  579.  
  580. (exit)
  581. ;///
  582.